﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;

using MongoDB.Bson.Serialization.Attributes;

namespace BusinessManagementStudio.Models.BusinessObject.Entities
{
    [BsonIgnoreExtraElements]
    public class Invoice : MongoEntity
    {
        public String InvoiceNo { get; set; }
        public String QuotationNo { get; set; }
        public String PONo { get; set; }
        public String ServiceOrderNo { get; set; }
        public String WorkOrderNo { get; set; }
        [DisplayFormat(DataFormatString = "{0:yyyy-MM-dd}",
               ApplyFormatInEditMode = true)]
        public DateTime InvoiceDate { get; set; }
        public String ServiceDetail { get; set; }
        public String Location { get; set; }
        public String VendorNo { get; set; }
        [DisplayFormat(DataFormatString = "{0:dd-MMMM-yyyy}",
               ApplyFormatInEditMode = true)]
        public DateTime WorkCompletionDate { get; set; }
        public decimal TotalAmount { get; set; }
        public String CompanyType { get; set; }
        public String CompanyName { get; set; }
        public String ReceivedRef { get; set; }
        [DisplayFormat(DataFormatString = "{0:yyyy-MM-dd HH:mm}",
               ApplyFormatInEditMode = true)]
        public DateTime? ReceivedDate { get; set; }
        public bool IsReceived { get; set; }
    }
}